package com.wei.miaosha.dao;

import com.wei.miaosha.domain.MiaoshaUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

/**
 * Created by Weizichen on 2018/8/9.
 * desc:秒杀dao
 */
@Mapper
public interface MiaoshaUserDao {
    @Select("select * from miaosha_user where id=#{id}")
    MiaoshaUser getById(@Param("id") long id);
    @Update("UPDATE miaosha_user SET password=#{password} WHERE id=#{id}")
    void update(MiaoshaUser updateUser);
}
